// Created by liusc on 2020/8/5-9:24.
<template>
  <div>
    <el-dialog
      :title="isEdit ? '编辑预算任务' : '新增预算任务'"
      :visible.sync="dialogVisible"
      width="1200px"
      :close-on-click-modal="false"
    >
      <el-form
        ref="edit-form"
        :model="form"
        :rules="rules"
        class="form-wrap"
        label-width="auto"
      >
        <el-form-item label="预算编号" prop="budgetCode">
          <el-input
            v-model="form.budgetCode"
            placeholder="请输入预算编号"
            readonly="readonly"
          />
        </el-form-item>

        <el-form-item label="申请名称" prop="applyName">
          <el-input
            v-model="form.applyName"
            placeholder="请输入申请名称"
            readonly="readonly"
          />
        </el-form-item>

        <el-form-item label="选择部门" prop="applyDept">
          <el-select
            v-model="form.applyDept"
            multiple
            placeholder="请选择部门"
            disabled="disabled"
          >
            <el-option
              v-for="item in lists"
              :key="item.value"
              :label="item.label"
              :value="item.value"
            >
            </el-option>
          </el-select>
        </el-form-item>

        <el-form-item label="模板" prop="templateName">
          <el-input
            v-model="form.templateName"
            placeholder="请输入模板"
            readonly="readonly"
          />
        </el-form-item>

        <el-form-item label="申请时间" prop="applyTime">
          <el-date-picker
            type="datetimerange"
            range-separator="至"
            start-placeholder="开始日期"
            end-placeholder="结束日期"
            v-model.trim="form.applyTime"
            format="yyyy-MM-dd"
            valueFormat="yyyy-MM-dd"
            @input="daterangeChange"
          >
          </el-date-picker>
        </el-form-item>

        <el-form-item label="备注" prop="remarks">
          <el-input
            v-model="form.remarks"
            placeholder="请输入备注"
            readonly="readonly"
          />
        </el-form-item>
      </el-form>

      <div slot="footer">
        <el-button @click="dialogVisible = false">返 回</el-button>
      </div>
    </el-dialog>
  </div>
</template>

<script src="./addition_look.js"></script>
<style scoped lang="scss">
@include formWrap(2);
</style>

